<!DOCTYPE html>
<html>
<head>
    @include("/common/init.html"){}
</head>
<body>
	@include("/common/commonunity_header.html",{title:'社区'}){}
	@include("/common/commonTie.html",{title:'社区'}){}
	<div class="layui-container" id="layuiContainer">
		<div class="layui-row layui-col-space15">
			<div class="layui-col-md8">
				<div class="fly-panel" style="margin-bottom: 0;">
					<div class="fly-panel-title fly-filter">
			           <a \@click="curId=0" :class="{'layui-this':curId===0}"  href="javascript:;" >综合</a>
			           <span class="fly-mid"></span>
			           <a \@click="curId=1" :class="{'layui-this':curId===1}" href="javascript:;" >未结</a>
			           <span class="fly-mid"></span>
			           <a \@click="curId=2" :class="{'layui-this':curId===2}"  href="javascript:;" >已结</a>
			           <span class="fly-mid"></span>
			           <a \@click="curId=3" :class="{'layui-this':curId===3}"  href="javascript:;" >精华</a>
        			</div>
				</div>
				<ul class="fly-list" id="flyList" v-show="curId===0 || curId===1 || curId===2 || curId===3">
					<li v-for="(value,index) in postList">
						<a v-bind:href="value.headUrl" class="fly-avatar">
							<img :src="value.avatar" :alt="value.nickname">
			            </a>
			            <h2>
			              <a class="layui-badge">{{value.type_name}}</a>
			              <a href="javascript:;" v-bind:onclick="value.skip">{{value.title}}</a>
			            </h2>
			            <div class="fly-list-info">
			            	<a v-bind:href="value.headUrl" link>
				                <cite>{{value.nickname}}</cite>
				                <i v-if="value.approve != null" class="iconfont icon-renzheng" v-bind:title="value.approve"></i>
				                <i class="layui-badge fly-badge-vip">{{value.levelName}}</i>
			              	</a>
			              	<span>{{value.c_time}}</span>
			              	<span class="fly-list-kiss layui-hide-xs" title="悬赏金币"><i class="iconfont icon-gold"></i>{{value.price}}</span>
			              	<span v-if="value.accept === 1" class="layui-badge fly-badge-accept layui-hide-xs">已结</span>
			                <span class="fly-list-nums"> 
			                	<i class="iconfont icon-pinglun1" title="回答"></i> {{value.replayCount}}
			                </span>
			            </div>
			            <div class="fly-list-badge">
			                <span  v-if="value.sticky_post === 1"  class="layui-badge layui-bg-black">置顶</span>
			            	<span v-if="value.fine_post === 1"  class="layui-badge layui-bg-red">精帖</span>
			            </div>
			        </li>
				</ul>
				@if(count! == 0){
					   <div style="margin-top:20px;">
				             	不好意思，没有数据哦，不要问我为什么，因为上天爱上了我.
				       </div>
				@}else{
					<div id="course_page"></div>
				@}
			</div>
			<div class="layui-col-md4">
	      		<div class="fly-panel fly-signin">
			        <div class="fly-panel-title">
			          		签到
			          <i class="fly-mid"></i> 
			          <a href="javascript:;" class="fly-link" id="LAY_signinHelp">说明</a>
			          <i class="fly-mid"></i> 
			          <a href="javascript:;" class="fly-link" id="LAY_signinTop">活跃榜<span class="layui-badge-dot"></span></a>
			          <span class="fly-signin-days">已连续签到<cite>${userSign.sign_count!}</cite>天</span>
			        </div>
			        <div class="fly-panel-main fly-signin-main">
			          @if(signed! == 1){
 							<button class="layui-btn layui-btn-disabled">今日已签到</button>
 							<span>获得了<cite>${experience!}</cite>金币</span>
 					  @}else{
				         <button class="layui-btn layui-btn-danger" id="LAY_signin">今日签到</button>
				         <span>可获得<cite>${experience!}</cite>金币</span>
			         @}
			        </div>
			     </div>
			     <div class="fly-panel fly-rank fly-rank-reply" id="LAY_replyRank">
			     	<h3 class="fly-panel-title">回贴周榜</h3>
        				<dl>
        				   @for(item in weekReplayList!){
	        				   <dd>
						            <a href="${basePath}/my/u/${item.replay_user_id!}">
						                <img src="${item.avatar!}"><cite>${item.nickname!}</cite><i>${item.count!}次回答</i>
						            </a>
						       </dd>
					        @}
        				</dl>
			     </div>
			     <dl class="fly-panel fly-list-one">
			     	<dt class="fly-panel-title">本周热议</dt>
			        @for(item in weekHeatReplayList!){
				       	<dd>
				          <a href="${basePath}/jie/page/${item.id}">${item.title!}</a>
				          <span><i class="iconfont icon-pinglun1"></i>${item.count!}</span>
				        </dd>
			         @}
			     </dl>
			     <div class="fly-panel">
				        <div class="fly-panel-title">
				          	广告待添加
				        </div>
				        <div class="fly-panel-main">
				          <a href="http://layim.layui.com/?from=fly" target="_blank" class="fly-zanzhu" time-limit="2017.09.25-2099.01.01" style="background-color: #5FB878;">LayIM 3.0 - layui 旗舰之作</a>
				        </div>
      			 </div>
			</div>
		</div>
	</div>
	<input type="hidden" id="basetypeId" value="${type!}">
	<input type="hidden" id="baseCuridId" value="${curid!}">
	<script>
	layui.cache.page ='user';
	layui.config({
	  version: "3.0.0"
	  ,base: '${baseStaticUrl}/mods/'
	}).extend({
	  fly: 'index'
	}).use('fly');
	</script>
	<script src="${baseStaticUrl}/layui/lay/modules/util.js"></script>
	<script src="${basePath}/js/pagePost.js"></script>	
</body>